#ifndef PROCESSBAR_H
#define PROCESSBAR_H

#include <string>

class processBar
{
public:
	processBar(char character='='
			,const std::string& s="|/-\\")
		:_ch(character)
		,_sign(s)
	{
		_buff.resize(100);
	}
	
	processBar(const processBar& rhs)
	{
		_ch=rhs._ch;
		_sign=rhs._sign;
		_buff=rhs._buff;
	}
	
	processBar& operator = (processBar rhs)
	{
		std::swap(*this,rhs);
		return *this;
	}

	void work(int rate);
	void clear();

private:
	char _ch='=';
	std::string _sign;
	std::string _buff;
};

#endif
